/**  
 * =====================================================
 * @Title: BaseTestStartSpring.java
 * @author airben 
 * @date 2015-5-14
 * @version V1.0  
 * =====================================================
 */
package cn.nawang.ebeim.ui.controler;

import org.junit.Before;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.ContextHierarchy;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.test.context.web.WebAppConfiguration;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext;

/**
 * @Description: <pre>
 * 
 * </pre>
 */
@RunWith(SpringJUnit4ClassRunner.class)
@WebAppConfiguration(value = "webapp")
@ContextHierarchy({
//		@ContextConfiguration(name = "parent", locations = "classpath:conf/applicationContext.xml"),
		@ContextConfiguration(name = "child", locations = "classpath:ui-servlet.xml") })

public abstract class BaseTestStartSpring {
	@Autowired
	protected WebApplicationContext wac;
	protected MockMvc mockMvc;

	@Before
	public void setUp() {
		mockMvc = MockMvcBuilders.webAppContextSetup(wac).build();
	}
}
